#include <cstdio>
#include <cmath>
#include <cstdlib>
#include <queue>

using namespace std;

typedef long long ll;
typedef priority_queue<ll, vector<ll>, greater<ll> > Heap;

namespace my {
    const int size=100000;

    int max(int a, int b) {return a>b ? a : b;}

    int main() {
        freopen("two.in", "r", stdin);
        freopen("two.out", "w", stdout);

        static Heap h[size+1];
        int n, q;
        scanf("%d %d", &n, &q);
        for (int i=1; i<=n; i++) {
            ll m, k;
            scanf("%lld %lld", &m, &k);
            h[m].push(m*m+k);
        }

        int ans=n;
        for (int i=1; i<=q; i++) {
            int opt;
            ll x, y;
            scanf("%d %lld %lld", &opt, &x, &y);
            if (opt==1) {
                ans++;
                h[x].push(x*x+y);
            } else {
                int t=sqrt(y);
                for (int j=max(x-t, 0); j<=x+t && j<=size; j++) {
                    for (; !h[j].empty() && -2LL*j*x+h[j].top()<=y-x*x; h[j].pop()) {
                        ans--;
                    }
                }
            }
            printf("%d\n", ans);
        }

        fclose(stdin);
        fclose(stdout);
        return 0;
    }
};

int main() {return my::main();};
